
<template>
  <div class="personal">
    <nav class="nav">
       <router-link class="iconfont icon-ziyuan left"  :to="{path:'setup'}" ></router-link>
      <router-link class="iconfont icon-lingdang right" :to="{path:'message'}" ></router-link>
    </nav>
    <div class="banner">
      <div class="center">
        <div class="user">
          <span class="userimg" :style="userimg"></span>
        </div>
        <p class="uname">旺仔牛奶</p>
      </div>
    </div>
    <div class="msg">
      <div class="msgwrap">
        <div class="commsg">
          <span>关注</span><br />
          98
        </div>
        <div class="commsg">
          <span>粉丝</span><br />
          5314
        </div>
        <div class="commsg">
          <span>帮助</span><br />
          0
        </div>
        <div class="commsg">
          <span>消息</span><br />
          10057
        </div>
        <div class="commsg">
          <span>反馈</span><br />
          9875
        </div>
      </div>
    </div>
    <div class="detail">
      <div class="menulist">
        <div class="myorder">我的订单 <span> {{this.$store.state.shopCarList.length}}</span></div>
        <div class="mymenu" @click="gomenu">菜谱 <span> 2</span></div>
        <div class="mywork">笔记 <span> 1</span></div>
        <div class="mymore">更多 <span> 1</span></div>
      </div>

    </div>
  </div>
</template>

<script>
import "../../../static/css/personalIcon/iconfont.css";
export default {
  data() {
    return {
      isShow:false,
      userimg: {
        background:
          " url(" +
          require("../../../static/images/prosonal/userimg.jpg") +
          ")center center no-repeat",
        backgroundSize: "100% 100%",
        width: "80px",
        height: "80px",
        borderRadius: "50%",
        display: "block",
      },
    }
    },
    methods:{
      gomenu(){
        this.$router.push("/mymenu")
      }
    }
};
</script>

<style scoped lang="less">
.detail{
  position: relative;
  top: -20px;
  width: 100%;
  height: 300px;
   background-color: #fff;
    border-radius: 15px  15px 0 0;
  border: 1px #fff solid;
}
.menulist{
  width: 50%;
  position: absolute;
  top: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  height: 3rem;
  border: 1px #ccc solid;
  border-radius: .2rem;
  font-size: 14px;
    .myorder{
      float: left;
      width: 50%;
      height: 1.5rem;
      line-height: 1.5rem;
      text-align: center;
      border-right: 1px #ccc solid;
      border-bottom: 1px #ccc solid;
      box-sizing: border-box;
      position: relative;
    }
    .mymenu{
     float: left;
      width: 50%;
      height: 1.5rem;
      line-height: 1.5rem;
      text-align: center;
      border-bottom: 1px #ccc solid;
      box-sizing: border-box;
        position: relative;
    }
    .mywork{
      float: left;
      width: 50%;
      height: 1.5rem;
      line-height: 1.5rem;
      text-align: center;
      border-right: 1px #ccc solid;
      box-sizing: border-box;
        position: relative;
    }
    .mymore{
      float: left;
      width: 50%;
      height: 1.5rem;
      line-height: 1.5rem;
      text-align: center;
      box-sizing: border-box; 
        position: relative;    
    }
          span{
        width: 0.5rem;
        height: 0.5rem; 
        line-height: .5rem;
        border-radius: 50%;
        background-color: #fb5f49;
        color:#fff;
        position: absolute;
        right: 0;
        top: 0rem;
      }
}
.dnav{
  position: absolute;
  left: 0;
  width: 100%;
  height: 50px;
  line-height: 50px;

  display: flex;

  .menu1,.work1{
    flex: 1;
    width: 50%;
    height: 50px;
    line-height: 50px;
    text-align: center;
    position: relative;
  }
    .menu1:after{
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
      display: block;
      content: "";
      width: 50px;
      height: 3px;
      background-color: #f3d02a;

  }

}
.clearfix{
  display: block;
  content: "";
  clear: both;
}
.work{
  position: absolute;
  top: 50px;
  left: 50px;
}

.msg{
  width: 100%;
  height: 50px;
  background-color: #f3d02a;
  padding-bottom: 20px;
  .msgwrap{
      width: 70%;
      height: 100%;
      margin: 0 auto;
      display: flex;
      text-align: center;
      font-size: 12px;
      .commsg{
          flex: 1;
          color: #666;
          span{
            font-size: 14px;
          }
      }
  }
}
.banner {
  width: 100%;
  height: 130px;
  background-color: #f3d02a;
  position: relative;
  text-align: center;
  .user {
    width: 80px;
    height: 80px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }
  .uname {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    font-size: 17px;
    bottom: 0;
  }
}
.nav {
  width: 100%;
  height: 50px;
  line-height: 50px;
  position: relative;
  background-color: #f3d02a;
  display: flex;
  .left {
    flex: 1;
    padding-left: 10px;
    font-size: 18px;
    text-decoration: none;
  }
  .right {
    flex: 1;
    text-align: right;
    padding-right: 10px;
    font-size: 18px;
    text-decoration: none;
  }
}
</style>